<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib uri="http://displaytag.sf.net" prefix="display"%>
<link href="../Admin-CSS/style.css" rel="stylesheet" type="text/css" />


<s:form method="post" action="" namespace="/admin"
	theme="simple">
	<table width="100%" align="center">
		<tr>
			<td height="40" class="sectionheading bottom-border">
				Banner Preferences and Settings
			</td>
		</tr>
		<tr>
			<td>
				<s:actionerror cssClass="Note-red" />
				<s:actionmessage cssClass="verdana11greynormal" />
			</td>
		</tr>
		<tr>
			<td>
				<s:hidden name="bannerSettings.id" value="%{bannerSettings.id}" />
			</td>
		</tr>
		<tr>
			<td>
				<table width="100%" border="0" cellpadding="0" cellspacing="0" class="Textfiled-border">
					<tr>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							Format Name
						</td>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							Number Of Banners
						</td>
						<td align="center" width="20%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							Type
						</td>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							(Max) Width [px]
						</td>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							(Max) Height [px]
						</td>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							Base width/height [px]
						</td>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							Status
						</td>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">
							Active Campaigns
						</td>
						<td align="center" width="10%" bgcolor="#E9E9E9" class="right-border verdana12darkgreybold">&nbsp;
							Action
						</td>
					</tr>
				<s:iterator value="bannerSettingsList" status="rowstatus">
					<s:hidden name="additionalOptionsFeesMap[%{id}].id" value="%{id}" />
					<s:set name="classCSS" value="%{'Textfiled-no-border-odd'}" var="classCSS"></s:set>
					<s:set name="bgColor" value="%{'#FFFFFF'}" var="bgColor"></s:set>

					<s:if test="#rowstatus.even">
						<s:set var="classCSS" value="%{'Textfiled-no-border-even'}"></s:set>
						<s:set var="bgColor" value="%{'#F8F8F8'}"></s:set>
					</s:if>
					<tr>
						<td height="26" align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							<s:property value="formatName" />
						</td>
						<td align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							<s:property value="noOfFormat" />
						</td>
						<td align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							<s:if test="#attr.type == 1">fix width - variable height</s:if>
							<s:elseif test="#attr.type == 2">variable width - fix height</s:elseif>
							<s:elseif test="#attr.type == 3">fix width and height</s:elseif>
						</td>
						<td align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							<s:property value="maxWidth" />
						</td>
						<td align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							<s:property value="maxHieght" />
						</td>
						<td align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							<s:property value="baseHieghtWidth" />
						</td>
						<td align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							<s:if test="#attr.enable == true">Enable</s:if>
							<s:elseif test="#attr.enable == false">Disable</s:elseif>
						</td>
						<td align="center" class="verdana12blacknormal right-border" bgcolor="<s:property value="%{bgColor}" />">
							10
						</td>
						<td id="mddm" valign="top" align="center" class="verdana12blacknormal" bgcolor="<s:property value="%{bgColor}" />">
							<a class="navi-link" href="#" onmouseover="mopen('<s:property value="#rowstatus.count" />', this, 'navi-link', 'right', <s:property value="#rowstatus.count" />)" onmouseout="mclosetime()">Select</a>
							<div style="visibility: hidden;" id="<s:property value="#rowstatus.count" />" onmouseover="mcancelclosetime()" onmouseout="mclosetime()">
							<a href="toggleBannerSettings.htm?settingId=<s:property value="id" />"><s:if test="enable == true">Disable</s:if><s:else>Enable</s:else></a>
							<a href="editBannerSettings.htm?settingId=<s:property value="id" />">Edit</a>
							<s:if test="enable == true">
								<a href="javascript: wantToDeleteWithURL('deleteBannerSettings.htm?id=<s:property value="id" />', 'Do you want to delete this setting?')">Delete</a>
							</s:if>
							</div>
						</td>
					</tr>
				</s:iterator>
				</table>
				<input type="button" value="add new format" onclick="top.location.href='showBannerFormats.htm'">
			</td>
		</tr>
	</table>
</s:form>